package com.zut.service.impl;

import com.zut.dao.RecruitmentDao;
import com.zut.domain.Recruitment;
import com.zut.service.RecruitmentService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class RecruitmentServiceImpl implements RecruitmentService {
    @Autowired
    private RecruitmentDao recruitmentDao;


    public List<Recruitment> getAll() {
        return recruitmentDao.getAll();
    }

    public boolean insert(Recruitment post) {
        return recruitmentDao.insert(post) > 0;
    }

    public boolean deleteById(String id) {
        return recruitmentDao.deleteById(id) > 0;
    }

    public boolean update(Recruitment post) {
        return recruitmentDao.update(post) > 0;
    }
}
